#ifndef RSSITEM_H
#define RSSITEM_H

#include <QString>
#include <QDate>
#include <QTreeWidget>
#include <QWebView>


class RssItem : QObject {
        Q_OBJECT

    private:
        QString title;
        QString link;
        QString description;
        QString date;
        QString feedName;
        bool seen;
        bool hidden;

    public:
        RssItem(const QString &feedName, const QString &title, const QString &link, const QString &description, const QString &date, bool seen = false, bool hidden = false);
        ~RssItem() { }

        void updateRepresentation(QWebView *view);
        void deleteRepresentation(QTreeWidget *widget);

        void setHidden(bool hidden) {
            this->hidden = hidden;
        }

        void setSeen(bool seen) {
            this->seen = seen;
        }

        QString getTitle() const {
            return title;
        }

        QString getLink() const {
            return link;
        }

        QString getDescription() const {
            return description;
        }

        QString getDate() const {
            return date;
        }

        QString getFeedName() const {
            return feedName;
        }

        bool isSeen() const {
            return seen;
        }

        bool isHidden() const {
            return hidden;
        }

};


#endif // RSSITEM_H
